package com.gzist.blog_system.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.gzist.blog_system.domain.Permission;
import com.gzist.blog_system.domain.User;
import com.gzist.blog_system.domain.vo.UserInfoParams;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * @Entity generator.domain.User
 */
public interface UserMapper extends BaseMapper<User> {

    List<Permission> getPermissions(Long id);

    boolean updateUserInfo(UserInfoParams userInfoParams);

    boolean updateAvatar(@Param("id") Long id, @Param("userPic") String userPic);

    void updatePwd(@Param("enNewPwd") String enNewPwd, @Param("id") Long id);

    void register(@Param("username") String username, @Param("password") String password);
}




